<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
	<head>
		<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
		<title>
			Document
		</title>
		<link rel="stylesheet" href="Public/Admin/Css/bootstrap.min.css" />
		<link rel="stylesheet" href="__PUBLIC__/Css/common.css" />
		<script type="text/javascript" src='Public/jquery-1.8.2.min.js'></script>
		<style type="text/css">body {
			margin-bottom: 100px;
		}
		</style>
	</head>
	<body>
		<div class="container-fluid">
			<div class="row-fluid">
				<div class="span12">
					<form action="" method="post">
						<table class='table table-bordered table-hover'>
							<tr>
								<th>
									货品ID
								</th>
								<?php foreach ($arrData as $k=>$v){?>
								<th>
									<?php echo $k?>
								</th>
								<?php }?>
								<th>
									库存
								</th>
								<th>
									货号
								</th>
							</tr>
							<tr class="info">
								<td>
									添加货品
								</td>
								<?php foreach ($arrData as $v){?>
								<td>
									<select name="combine[]">
										<option value="0">
											-请选择-
										</option>
										<?php foreach ($v as $key=>$value){?>
										<option value="<?php echo $value['gaid']?>" <?php if(in_array($value['gaid'],$oldData['combine'])){?>
                selected
               <?php }?>>
											<?php echo $value['gavalue']?>
										</option>
										<?php }?>
									</select>
								</td>
								<?php }?>
								<td>
									<input type="text" name='number'  value="<?php echo $oldData['number']?>" />
								</td>
								<td>
									<input type="text" name='inventory' value="<?php echo $oldData['inventory']?>"/>
								</td>
							</tr>
						</table>
						<input type="hidden" name="glid" value="<?php echo $_GET['glid']?>" />
						<input type="submit" value='保存编辑' class="btn btn-primary"/>
					</form>
				</div>
			</div>
		</div>
	</body>
</html>